<template>
	<view>
		<uni-card>
			<view class="title">
				<text>{{info.title}}</text>
			</view>
		</uni-card>
		
		<view class="content">
		<rich-text class="richText" :nodes="info.content"></rich-text>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				info: {}
			}
		},
		methods: {

		},
		onLoad(e) {
			uni.showLoading({
				title: '加载中',
				mask: false
			});
			uni.request({
				url: 'https://unidemo.dcloud.net.cn/api/news/36kr/' + e.newsid,
				method: 'GET',
				data: {},
				success: res => {
					console.log(res)
					this.info = res.data
					uni.hideLoading()
				},
				fail: () => {},
				complete: () => {}
			});
		}
	}
</script>

<style>
.title{font-size: 36upx; font-weight: 700; line-height: 1.6em;}
.content{padding: 20upx; font-weight: 500; line-height: 1.5em; font-size: 29upx; color: #2C405A;}
</style>
